function export_result_lapse(RS, scale_vec, xl, fig_title, lr, lr_target, folder_tex_cf)

% figure settings
scrsz = get(0,'ScreenSize');
set(0,'defaulttextinterpreter','latex')
set(0,'defaultaxesfontname','times')
set(0,'DefaultAxesFontSize',29); 
set(0,'DefaultTextFontSize',35);
set(0,'DefaultAxesTitleFontWeight','bold');

% font size
fs1 = 42;

% colors
color1 = 'k';
color2 = [0.3 0.3 0.3]; % light gray

% marker
marker_size = 18; 
ms = 'o';

% line
ls = ':';
l_width  = 3;
l_width2 = 2;

% set x-axis ticks. 
ns = length(scale_vec);
if lr==0
    ii = find(scale_vec==1); % baseline value 
elseif lr==1
    ii = find(scale_vec==lr_target); % baseline value 
end

i_vec = find(scale_vec>=0.5 & scale_vec<=2);
xtick_set = i_vec;
xtick_label = num2cell(scale_vec);
xtick_label = xtick_label(xtick_set,:);
xtick_set = 1:length(xtick_label);

xl = 'cost ($c^1_{jk}$) multiplier';

% horizontal line at 0
y0 = zeros(size(i_vec));

%% prices
fig_position = scrsz./[1.5 1.5 4 3]; % home office dell monitor setting
fig = figure('Color','w','Position',fig_position);
uy = 1.2*max(RS.p1_vec(i_vec));
ly = -0.8*uy;
hold on
plot(RS.p1_vec(i_vec),...
    'Color',color1,'linewidth',l_width,...
    'marker',ms,'markeredgecolor',color1,'markerfacecolor',[1 1 1],'markersize',marker_size);
ylabel('\% change', 'Interpreter','Latex')
plot(y0, 'linestyle', ls, 'Color', color2, 'linewidth',l_width2)
xlabel(xl,'Interpreter','Latex')
set(gca,'Xtick', xtick_set, 'XTickLabel', xtick_label);
title('\% change in initial rate, $p_{j1}$', 'Interpreter','Latex', 'FontSize', fs1,...
    'FontWeight','bold')
xlim([0.7*min(xtick_set) 1.1*max(xtick_set)])
ylim([ly uy])
print('-depsc2',[fullfile(folder_tex_cf, 'cf_p1_lapse') '.eps']);

ly = 1.5*min(RS.p2_vec(i_vec));
uy = 1.3*max(RS.p2_vec(i_vec));
fig = figure('Color','w','Position',fig_position);
hold on
plot(RS.p2_vec(i_vec),...
    'Color',color1,'linewidth',l_width,...
    'marker',ms,'markeredgecolor',color1,'markerfacecolor',[1 1 1],'markersize',marker_size);
ylabel('\% change', 'Interpreter','Latex')
plot(y0, 'linestyle', ls, 'Color', color2, 'linewidth',l_width2)
xlabel(xl,'Interpreter','Latex')
set(gca,'Xtick', xtick_set, 'XTickLabel', xtick_label);
title('\% change in revised rate, $p_{jk2}$', 'Interpreter','Latex', 'FontSize', fs1)
ylim([ly uy])
xlim([0.7*min(xtick_set) 1.1*max(xtick_set)])
print('-depsc2',[fullfile(folder_tex_cf, 'cf_p2_lapse') '.eps']);

%% n_insurer
ly = 2*min(RS.n_vec(i_vec));
uy = 1.3*max(RS.n_vec(i_vec));
fig = figure('Color','w','Position',fig_position);
hold on
plot(RS.n_vec(i_vec),...
    'Color',color1,'linewidth',l_width,...
    'marker',ms,'markeredgecolor',color1,'markerfacecolor',[1 1 1],'markersize',marker_size);
ylabel('\% change', 'Interpreter','Latex')
plot(y0, 'linestyle', ls, 'Color', color2, 'linewidth',l_width2)
xlabel(xl,'Interpreter','Latex')
set(gca,'Xtick', xtick_set, 'XTickLabel', xtick_label);
title('\% change in \# of fringe entrants', 'Interpreter','Latex', 'FontSize', fs1)
ylim([ly uy])
xlim([0.7*min(xtick_set) 1.1*max(xtick_set)])
print('-depsc2',[fullfile(folder_tex_cf, 'cf_n_lapse') '.eps']);

%% profits 
ly = 1.5*min(RS.profit_major(i_vec));
uy = 1.3*max(RS.profit_major(i_vec));
fig = figure('Color','w','Position',fig_position);
hold on
plot(RS.profit_major(i_vec),...
    'Color',color1,'linewidth',l_width,...
    'marker',ms,'markeredgecolor',color1,'markerfacecolor',[1 1 1],'markersize',marker_size);
ylabel('\% change', 'Interpreter','Latex')
plot(y0, 'linestyle', ls, 'Color', color2, 'linewidth',l_width2)
xlabel(xl,'Interpreter','Latex')
set(gca,'Xtick', xtick_set, 'XTickLabel', xtick_label);
title('\% change in major firm profit','Interpreter','Latex', 'FontSize', fs1)
ylim([ly uy])
xlim([0.7*min(xtick_set) 1.1*max(xtick_set)])
print('-depsc2',[fullfile(folder_tex_cf, 'cf_w_m_lapse') '.eps']);

ly = 1.5*min(RS.profit_minor(i_vec));
uy = 1.2*max(RS.profit_minor(i_vec));
fig = figure('Color','w','Position',fig_position);
hold on
plot(RS.profit_minor(i_vec),...
    'Color',color1,'linewidth',l_width,...
    'marker',ms,'markeredgecolor',color1,'markerfacecolor',[1 1 1],'markersize',marker_size);
ylabel('\% change', 'Interpreter','Latex')
plot(y0, 'linestyle', ls, 'Color', color2, 'linewidth',l_width2)
xlabel(xl,'Interpreter','Latex')
set(gca,'Xtick', xtick_set, 'XTickLabel', xtick_label);
title('\% change in fringe profit','Interpreter','Latex', 'FontSize', fs1)
ylim([ly uy])
xlim([0.7*min(xtick_set) 1.1*max(xtick_set)])
print('-depsc2',[fullfile(folder_tex_cf, 'cf_w_f_lapse') '.eps']);

%% consumer welfare & enrollment
ly = -1.3*max(abs(RS.welfare_vec(i_vec)));
uy = 0.6*max(abs(RS.welfare_vec(i_vec)));
fig = figure('Color','w','Position',fig_position);
hold on
plot(RS.welfare_vec(i_vec),...
    'Color',color1,'linewidth',l_width,...
    'marker',ms,'markeredgecolor',color1,'markerfacecolor',[1 1 1],'markersize',marker_size);
ylabel('\% change', 'Interpreter','Latex')
plot(y0, 'linestyle', ls, 'Color', color2, 'linewidth',l_width2)
xlabel(xl,'Interpreter','Latex')
set(gca,'Xtick', xtick_set, 'XTickLabel', xtick_label);
title('\% change in consumer welfare','Interpreter','Latex', 'FontSize', fs1)
xlim([0.7*min(xtick_set) 1.1*max(xtick_set)])
print('-depsc2',[fullfile(folder_tex_cf, 'cf_w_c_lapse') '.eps']);

ly = -1.5*max(abs(RS.enroll_vec(i_vec)));
uy = 2*max(RS.enroll_vec(i_vec));
uy=0.4;
fig = figure('Color','w','Position',fig_position);
hold on
plot(RS.enroll_vec(i_vec),...
    'Color',color1,'linewidth',l_width,...
    'marker',ms,'markeredgecolor',color1,'markerfacecolor',[1 1 1],'markersize',marker_size);
ylabel('\% change', 'Interpreter','Latex')
plot(y0, 'linestyle', ls, 'Color', color2, 'linewidth',l_width2)
xlabel(xl,'Interpreter','Latex')
set(gca,'Xtick', xtick_set, 'XTickLabel', xtick_label);
title('\% change in privately insured rate', 'Interpreter','Latex', 'FontSize', fs1)
ylim([ly uy])
xlim([0.7*min(xtick_set) 1.1*max(xtick_set)])
print('-depsc2',[fullfile(folder_tex_cf, 'cf_insured_lapse') '.eps']);
